package model

type DictItem struct {
	Id         uint64 `json:"id"`
	DictCode   string `json:"dict_code" dc:"字典编码"`
	DictName   string `json:"dict_name" dc:"字典名称"`
	DictStatus uint   `json:"dict_status" dc:"字典状态：0-禁用、1-正常"`
}

type DictFormInput struct {
	DictCode   string `json:"dict_code" v:"max-length:30" dc:"字典编码"`
	DictName   string `json:"dict_name" v:"required|max-length:30" dc:"字典名称"`
	DictStatus uint   `json:"dict_status" v:"integer|in:0,1" dc:"字典状态：0-禁用、1-正常"`
}

type DictDataListInput struct {
	DictId   string `json:"dict_id" in:"query" v:"integer|min:1" dc:"字典id"`
	DictCode string `json:"dict_code" in:"query" dc:"字典编码"`
	PageSizeReq
}

type DictDataItem struct {
	Id         uint64 `json:"id"`
	ItemName   string `json:"item_name"`
	ItemValue  string `json:"item_value"`
	ItemRemark string `json:"item_remark"`
	ItemSort   int    `json:"item_sort"`
	ItemStatus uint   `json:"item_status"`
	DictId     uint64 `json:"dict_id"`
}

type DictDataFormInput struct {
	ItemName   string `json:"item_name" v:"required|max-length:30" dc:"字典项名称"`
	ItemValue  string `json:"item_value" v:"required|max-length:30" dc:"字典项值"`
	ItemRemark string `json:"item_remark" v:"max-length:150" dc:"字典项备注"`
	ItemSort   int    `json:"item_sort" v:"integer|between:0,1000" dc:"字典项排序"`
	ItemStatus uint   `json:"item_status" v:"integer|in:0,1" dc:"状态(0隐藏,1显示)"`
	DictId     uint64 `json:"dict_id" v:"integer|min:1" dc:"字典id"`
}
